package com.zheng.hr.dao.model;

import com.baomidou.mybatisplus.enums.IdType;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableName;
import com.zheng.common.base.BaseEntity;
import com.zheng.common.base.PageEntity;

import java.io.Serializable;

/**
 * <p>
 * 审批表
 * </p>
 *
 * @author likun
 * @since 2018-04-28
 */
@TableName("hr_approval")
public class HrApproval extends PageEntity {
    private static final long serialVersionUID = 1L;
    public static final int APPROVAL_STATUS = 1;
    public static final int PASS_STATUS = 2;
    public static final int YEAR_LEAVE_STATUS = 7;
    public static final int OFF_LEAVE_STATUS = 8;
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    /**
     * 审核名称
     */
    @TableField("sp_name")
    private String spName;
    /**
     * 审核状态：1审批中；2 已通过；3已驳回；4已取消；6通过后撤销；10已支付
     */
    @TableField("sp_status")
    private Integer spStatus;
    /**
     * 用户username
     */
    @TableField("apply_user_name")
    private String applyUserName;

    @TableField("apply_name")
    private String applyName;
    /**
     * 用户部门信息
     */
    @TableField("apply_org")
    private String applyOrg;
    /**
     * 审批人数组
     */
    @TableField("approval_name")
    private String approvalName;
    /**
     * 审核时间
     */
    @TableField("apply_time")
    private Long applyTime;
    /**
     * 天数（请假、出差等）
     */
    @TableField("duration_day")
    private Double durationDay;
    @TableField("duration_hour")
    private Integer durationHour;
    /**
     * 开始时间
     */
    @TableField("begin_time")
    private Long beginTime;
    /**
     * 结束时间
     */
    @TableField("end_time")
    private Long endTime;
    /**
     * 补卡时间
     */
    @TableField("checkin_time")
    private Long checkinTime;
    /**
     * 非正常状态
     */
    @TableField("checkin_status")
    private String checkinStatus;

   @TableField("sp_num")
    private String spNum;

    private String reason;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getSpName() {
        return spName;
    }

    public void setSpName(String spName) {
        this.spName = spName;
    }

    public Integer getSpStatus() {
        return spStatus;
    }

    public void setSpStatus(Integer spStatus) {
        this.spStatus = spStatus;
    }

    public String getApplyUserName() {
        return applyUserName;
    }

    public void setApplyUserName(String applyUserName) {
        this.applyUserName = applyUserName;
    }

    public String getApplyName() {
        return applyName;
    }

    public void setApplyName(String applyName) {
        this.applyName = applyName;
    }

    public String getApplyOrg() {
        return applyOrg;
    }

    public void setApplyOrg(String applyOrg) {
        this.applyOrg = applyOrg;
    }

    public String getApprovalName() {
        return approvalName;
    }

    public void setApprovalName(String approvalName) {
        this.approvalName = approvalName;
    }

    public Long getApplyTime() {
        return applyTime;
    }

    public void setApplyTime(Long applyTime) {
        this.applyTime = applyTime;
    }

    public Double getDurationDay() {
        return durationDay;
    }

    public void setDurationDay(Double durationDay) {
        this.durationDay = durationDay;
    }

    public Long getBeginTime() {
        return beginTime;
    }

    public void setBeginTime(Long beginTime) {
        this.beginTime = beginTime;
    }

    public Long getEndTime() {
        return endTime;
    }

    public void setEndTime(Long endTime) {
        this.endTime = endTime;
    }

    public Long getCheckinTime() {
        return checkinTime;
    }

    public void setCheckinTime(Long checkinTime) {
        this.checkinTime = checkinTime;
    }

    public String getCheckinStatus() {
        return checkinStatus;
    }

    public void setCheckinStatus(String checkinStatus) {
        this.checkinStatus = checkinStatus;
    }

    public String getReason() {
        return reason;
    }

    public void setReason(String reason) {
        this.reason = reason;
    }

    public Integer getDurationHour() {
        return durationHour;
    }

    public void setDurationHour(Integer durationHour) {
        this.durationHour = durationHour;
    }

    public String getSpNum() {
        return spNum;
    }

    public void setSpNum(String spNum) {
        this.spNum = spNum;
    }

    @Override
    protected Serializable pkVal() {
        return id;
    }
    @Override
    public String toString() {
        return "HrApproval{" +
                "id=" + id +
                ", spName=" + spName +
                ", spStatus=" + spStatus +
                ", applyUserName=" + applyUserName +
                ", applyName=" + applyName +
                ", applyOrg=" + applyOrg +
                ", approvalName=" + approvalName +
                ", applyTime=" + applyTime +
                ", durationDay=" + durationDay +
                ", beginTime=" + beginTime +
                ", endTime=" + endTime +
                ", checkinTime=" + checkinTime +
                ", checkinStatus=" + checkinStatus +
                "}";
    }
}
